<?php
/**
* @version 1.0.0
* @package RSSearch! 1.0.0
* @copyright (C) 2011 www.rsjoomla.com
* @license GPL, http://www.gnu.org/copyleft/gpl.html
*/
defined('_JEXEC') or die('Restricted access');
if(file_exists(JPATH_SITE.DS.'components'.DS.'com_rssearch'.DS.'rssearch.php')){
	require_once (dirname(__FILE__).DS.'helper.php');
	
	$lang 			=& JFactory::getLanguage();
	$document		=&JFactory::getDocument();

	$lang->load('com_rssearch');

	$class_suffix	= $params->get('moduleclass_sfx');
	$itemid			= $params->get('itemid');
	if (!$itemid)
		$itemid = JRequest::getInt('Itemid');
		
	$show_btn		= $params->get('show_submit','yes');
	$limit			= $params->get('search_limit','5');
	$class_suffix 	= (empty($class_suffix)) ? '' : '_'.$class_suffix;
	$field_width 	= $params->get('field_width','210');
	$box_width		= $params->get('results_box_width','210');
	$nr_words		= $params->get('nr_words','80');
	

	$head = $document->getHeadData();

	if(!modRSSearchHelper::CheckHeadScript('mootools-more.js')) 
		if(modRSSearchHelper::isJ16())
			$head['scripts'][JURI::root(true).'/media/system/js/mootools-more.js'] = array('mime' => 'text/javascript', 'defer' => '', 'async' => '');
		else
			$head['scripts'][JURI::root(true).'/media/system/js/mootools-more.js'] = 'text/javascript';

	$document->setHeadData($head);
	
	
	require(JModuleHelper::getLayoutPath('mod_rssearch','default'));
}else{
	echo JText::_('RSF_MODULE_LIST_CHECK');
}
?>